<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <script src="vue.js"></script>
    <title>Title</title>
</head>
<body>
<div id="app">
    <input v-model="message" placeholder="edit me">
    <p>Message is: {{ message }}</p>

    <span>multiline message is:</span>
    <p style="white-space: pre-line;">{{ multiline }}</p>
    <br>
    <textarea v-model="multiline" placeholder="add multiple lines"></textarea>

    <input type="checkbox" id="checkbox" v-model="checked">
    <label for="checkbox">{{ checked }}</label>

    <div>
        <input type="checkbox" id="jack" value="Jack" v-model="checkedNames">
        <label for="jack">Jack</label>
        <input type="checkbox" id="john" value="John" v-model="checkedNames">
        <label for="john">John</label>
        <input type="checkbox" id="mike" value="Mike" v-model="checkedNames">
        <label for="mike">Mike</label>
        <br>
        <span>Checked names: {{ checkedNames }}</span>
    </div>

    <div>
        <input type="radio" id="one" value="One" v-model="picked">
        <label for="one">One</label>
        <br>
        <input type="radio" id="two" value="Two" v-model="picked">
        <label for="two">Two</label>
        <br>
        <span>Picked: {{ picked }}</span>
    </div>

    <div>
        <select v-model="selected">
            <option disabled value="">请选择</option>
            <option>A</option>
            <option>B</option>
            <option>C</option>
        </select>
        <span>Selected: {{ selected }}</span>
    </div>

    <input type="checkbox" v-model="toggle" v-bind:true-value="a" v-bind:false-value="b">{{ toggle }}

    <div>
        <input type="radio" v-model="radioPick" v-bind:value="c">
        <input type="radio" v-model="radioPick" v-bind:value="d">
        {{ radioPick }}
    </div>

    <input v-model.number="age" type="number">

    <input v-model.trim="msg">
</div>
</body>
</html>
<script>
    var app = new Vue({
        el: '#app',
        data: {
            message: 'default message',
            multiline: 'default multiline',
            checked: false,
            checkedNames:[],
            picked:'',
            selected:'',
            toggle: 'bbb',
            a: 'aaa',
            b: 'bbb',
            c: 'ccc',
            d: 'ddd',
            radioPick: 'ccc',
            age: 14,
            msg: 'msg'
        }
    });
</script>